#ifndef _TRIANGLE
#define _TRIANGLE

#include "Base.h"
#include "Vector.h"
#include "Ray.h"
#include "Matrix.h"

class Triangle
{
public:
  
  Vector A, B, C;
  
  fp zNear;
    
  Triangle(
    const Vector& _A=Vector(0,0,0),
    const Vector& _B=Vector(1,0,0),
    const Vector& _C=Vector(0,1,0)
  );
  Triangle(const Triangle& t);
  
  bool Intersect(const Ray& r);
};

#endif // _TRIANGLE
